package com.qf.spring.aop.proxy.statics;


import com.qf.spring.aop.service.UserService;
import com.qf.spring.aop.service.impl.UserServiceImpl;

/**
 * user的静态代理类
 */
public class UserServiceProxy implements UserService {

    //初始化user业务层接口的实现类
    private UserService userService = new UserServiceImpl();
    @Override
    public void login() {
        System.out.println("方法执行之前，打印日志");
        userService.login();
        System.out.println("方法执行之后，打印日志");
    }

    @Override
    public void loginOut() {
        System.out.println("方法执行之前，打印日志");
        userService.loginOut();
        System.out.println("方法执行之后，打印日志");
    }
}
